<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
      <link rel="icon" href="/public/favicon.ico" type="image/x-icon" />
    <meta name="description" content="">
    <meta name="author" content="">
    <meta name="keyword" content="">

    <title>Rain.文件上传床</title>

    <!-- Bootstrap core CSS -->
    <link href="../../../../public/assets/css/bootstrap.css" rel="stylesheet">
    <!--external css-->
    <link href="../../../../public/assets/font-awesome/css/font-awesome.css" rel="stylesheet" />
    
    <!-- Custom styles for this template -->
    <link href="../../../../public/assets/css/style.css" rel="stylesheet">
    <link href="../../../../public/assets/css/style-responsive.css" rel="stylesheet">
    <link rel="stylesheet" href="../../../../public/assets/css/to-do.css">

    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="/public/js/html5shiv.js"></script>
      <script src="/public/js/respond.min.js"></script>
    <![endif]-->

    <link href="http://cdn.bootcss.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet">
        <link rel="stylesheet" type="text/css" href="../../../../public/css/default.css">
        <link href="../../../../public/css/fileinput.css" media="all" rel="stylesheet" type="text/css" />
        <script src="/public/js/jquery.min.js" type="text/javascript"></script>
        <script>window.jQuery || document.write('<script src="js/jquery-1.11.0.min.js"><\/script>')</script>
        <script src="../../../../public/js/fileinput.js" type="text/javascript"></script>
        <!--简体中文-->
        <script src="../../../../public/js/locales/zh.js" type="text/javascript"></script>
        <!--繁体中文-->
        <script src="../../../../public/js/locales/zh-TW.js" type="text/javascript"></script>
        <script src="/public/js/bootstrap.min.js"></script>
  </head>

  <body >

  <section id="container" >
      <!-- **********************************************************************************************************************************************************
      TOP BAR CONTENT & NOTIFICATIONS
      *********************************************************************************************************************************************************** -->
      <!--header start-->
      
      <!--header end-->
      
      <!-- **********************************************************************************************************************************************************
      MAIN SIDEBAR MENU
      *********************************************************************************************************************************************************** -->
      <!--sidebar start-->
     
      <!--sidebar end-->
      
      <!-- **********************************************************************************************************************************************************
      MAIN CONTENT
      *********************************************************************************************************************************************************** -->
      <!--main content start-->
       <div class="htmleaf-container" >
                <header class="htmleaf-header">
                    <h1> Rain.文件上传床<span>基于Bootstrup实现的可预览文件上传床,文件大小不超过3M,上传的文件可以在服务器上暂存七天</span></h1>
                </header>
                <div class="container kv-main">
                    <!-- <div class="page-header"> -->
                    <!-- <h2>Bootstrap File Input Example</h2> -->
                    <!-- </div> -->
                    
                   
           
                    <form enctype="multipart/form-data" method="post" action="/index.php/index/index/upload">
                       <div class="form-group">
                            <input id="file-5" class="file" name="file" type="file" multiple data-preview-file-type="any" data-upload-url="#">
                            <br>
                        <button type="submit" class="btn btn-primary">Submit</button>
                        <button type="reset" class="btn btn-default">Reset</button>
                        </div>
                    </form>
                    
                    
                </div>
           
            </div>
      <section id="main-content" style="margin: auto;margin-right: 10%;margin-left: 10%;">
          <section class="wrapper">
          	<h3><i class="fa fa-angle-right"></i> 文件列表</h3>
          	
          	<!-- SIMPLE TO DO LIST -->
    

          	<!-- COMPLEX TO DO LIST -->			
              <div class="row mt">
                  <div class="col-md-12">
                      <section class="task-panel tasks-widget">
	                	<div class="panel-heading">
	                        <div class="pull-left"><h5><i class="fa fa-tasks"></i> 已经上传的文件列表，可以点击后面的图标下载，暂不支持修改和删除功能</h5></div>
	                        <br>
	                 	</div>
                          <div class="panel-body">
                              <div class="task-content">

                                  <ul class="task-list">
                                      {volist name="list" id="file_list"}
                                      <li>
                                          <div class="task-checkbox">
                                              <input type="checkbox" class="list-child" value=""  />
                                          </div>
                                          <div class="task-title">
                                              <span class="task-title-sp">{$file_list.file_name}</span>
                                              <span class="badge bg-warning">{$file_list.upload_time}</span>
                                              <div class="pull-right hidden-phone">
                                                  <a href="{$file_list.file_url}" download="{$file_list.file_name}" ><button title="点击即可下载" class="btn btn-success btn-xs"><i class=" fa fa-download"></i></button></a>
                                                  <button class="btn btn-primary btn-xs" title="暂不支持修改"><i class="fa fa-pencil"></i></button>
                                                  <button class="btn btn-danger btn-xs" title="暂不支持删除"><i class="fa fa-trash-o "></i></button>
                                              </div>
                                          </div>
                                      </li>
                                      {/volist}
                                      <!--<li>-->
                                          <!--<div class="task-checkbox">-->
                                              <!--<input type="checkbox" class="list-child" value=""  />-->
                                          <!--</div>-->
                                          <!--<div class="task-title">-->
                                              <!--<span class="task-title-sp">Extensive collection of plugins</span>-->
                                              <!--<span class="badge bg-theme">Cool</span>-->
                                              <!--<div class="pull-right hidden-phone">-->
                                                  <!--<button class="btn btn-success btn-xs"><i class=" fa fa-check"></i></button>-->
                                                  <!--<button class="btn btn-primary btn-xs"><i class="fa fa-pencil"></i></button>-->
                                                  <!--<button class="btn btn-danger btn-xs"><i class="fa fa-trash-o "></i></button>-->
                                              <!--</div>-->
                                          <!--</div>-->
                                      <!--</li>-->
                                      <!--<li>-->
                                          <!--<div class="task-checkbox">-->
                                              <!--<input type="checkbox" class="list-child" value=""  />-->
                                          <!--</div>-->
                                          <!--<div class="task-title">-->
                                              <!--<span class="task-title-sp">Free updates always, no extra fees.</span>-->
                                              <!--<span class="badge bg-success">2 Days</span>-->
                                              <!--<div class="pull-right hidden-phone">-->
                                                  <!--<button class="btn btn-success btn-xs"><i class=" fa fa-check"></i></button>-->
                                                  <!--<button class="btn btn-primary btn-xs"><i class="fa fa-pencil"></i></button>-->
                                                  <!--<button class="btn btn-danger btn-xs"><i class="fa fa-trash-o "></i></button>-->
                                              <!--</div>-->
                                          <!--</div>-->
                                      <!--</li>-->
                                      <!--<li>-->
                                          <!--<div class="task-checkbox">-->
                                              <!--<input type="checkbox" class="list-child" value=""  />-->
                                          <!--</div>-->
                                          <!--<div class="task-title">-->
                                              <!--<span class="task-title-sp">More features coming soon</span>-->
                                              <!--<span class="badge bg-info">Tomorrow</span>-->
                                              <!--<div class="pull-right hidden-phone">-->
                                                  <!--<button class="btn btn-success btn-xs"><i class=" fa fa-check"></i></button>-->
                                                  <!--<button class="btn btn-primary btn-xs"><i class="fa fa-pencil"></i></button>-->
                                                  <!--<button class="btn btn-danger btn-xs"><i class="fa fa-trash-o "></i></button>-->
                                              <!--</div>-->
                                          <!--</div>-->
                                      <!--</li>-->
                                      <!--<li>-->
                                          <!--<div class="task-checkbox">-->
                                              <!--<input type="checkbox" class="list-child" value=""  />-->
                                          <!--</div>-->
                                          <!--<div class="task-title">-->
                                              <!--<span class="task-title-sp">Hey, seriously, you should buy this </span>-->
                                              <!--<span class="badge bg-important">Now</span>-->
                                              <!--<div class="pull-right">-->
                                                  <!--<button class="btn btn-success btn-xs"><i class=" fa fa-check"></i></button>-->
                                                  <!--<button class="btn btn-primary btn-xs"><i class="fa fa-pencil"></i></button>-->
                                                  <!--<button class="btn btn-danger btn-xs"><i class="fa fa-trash-o "></i></button>-->
                                              <!--</div>-->
                                          <!--</div>-->
                                      <!--</li>                                      -->
                                  </ul>
                              </div>

                              <div class=" add-task-row">
                                  <!--<a class="btn btn-success btn-sm pull-left" href="index.html#">Add New Tasks</a>-->
                                  <!--<a class="btn btn-default btn-sm pull-right" href="index.html#">See All Tasks</a>-->
                              </div>
                          </div>
                      </section>
                  </div><!-- /col-md-12-->
              </div><!-- /row -->
			
			
          	<!-- SORTABLE TO DO LIST -->
			
              
			
		</section><! --/wrapper -->
      </section><!-- /MAIN CONTENT -->

      <!--main content end-->
      <!--footer start-->
      <footer class="site-footer">
          <div class="text-center">
              Copyright &copy; 2017.Rain.文件床<a target="_blank" href="http://sc.chinaz.com/moban/"></a>
              <a href="" class="go-top">
                  <i class="fa fa-angle-up"></i>
              </a>
          </div>
      </footer>
      <!--footer end-->
  </section>

    <!-- js placed at the end of the document so the pages load faster -->
    <script src="../../../../public/assets/js/jquery.js"></script>
    <script src="../../../../public/assets/js/bootstrap.min.js"></script>
    <script class="include" type="text/javascript" src="../../../../public/assets/js/jquery.dcjqaccordion.2.7.js"></script>
    <script src="../../../../public/assets/js/jquery.scrollTo.min.js"></script>
    <script src="../../../../public/assets/js/jquery.nicescroll.js" type="text/javascript"></script>


    <!--common script for all pages-->
    <script src="../../../../public/assets/js/common-scripts.js"></script>

    <!--script for this page-->
	<script src="/public/js/jquery-ui.js"></script>
    <script src="../../../../public/assets/js/tasks.js" type="text/javascript"></script>

    <script>
      jQuery(document).ready(function() {
          TaskList.initTaskWidget();
      });

      $(function() {
          $( "#sortable" ).sortable();
          $( "#sortable" ).disableSelection();
      });

    </script>
    
    
  <script>
      //custom select box

      $(function(){
          $('select.styled').customSelect();
      });

  </script>
<script>
    $('#file-zh').fileinput({
        language: 'zh',
        uploadUrl: '#',
        allowedFileExtensions : ['jpg', 'png','gif'],
    });
    $('#file-zh-TW').fileinput({
        language: 'zh-TW',
        uploadUrl: '#',
        allowedFileExtensions : ['jpg', 'png','gif'],
    });
    $("#file-0").fileinput({
        'allowedFileExtensions' : ['jpg', 'png','gif'],
    });
    $("#file-1").fileinput({
        uploadUrl: '#', // you must set a valid URL here else you will get an error
        allowedFileExtensions : ['jpg', 'png','gif'],
        overwriteInitial: false,
        maxFileSize: 1000,
        maxFilesNum: 10,
        //allowedFileTypes: ['image', 'video', 'flash'],
        slugCallback: function(filename) {
            return filename.replace('(', '_').replace(']', '_');
        }
	});
    /*
    $(".file").on('fileselect', function(event, n, l) {
        alert('File Selected. Name: ' + l + ', Num: ' + n);
    });
    */
	$("#file-3").fileinput({
		showUpload: false,
		showCaption: false,
		browseClass: "btn btn-primary btn-lg",
		fileType: "any",
        previewFileIcon: "<i class='glyphicon glyphicon-king'></i>"
	});
	$("#file-4").fileinput({
		uploadExtraData: {kvId: '10'}
	});
    $(".btn-warning").on('click', function() {
        if ($('#file-4').attr('disabled')) {
            $('#file-4').fileinput('enable');
        } else {
            $('#file-4').fileinput('disable');
        }
    });    
    $(".btn-info").on('click', function() {
        $('#file-4').fileinput('refresh', {previewClass:'bg-info'});
    });
    /*
    $('#file-4').on('fileselectnone', function() {
        alert('Huh! You selected no files.');
    });
    $('#file-4').on('filebrowse', function() {
        alert('File browse clicked for #file-4');
    });
    */
    $(document).ready(function() {
        $("#test-upload").fileinput({
            'showPreview' : false,
            'allowedFileExtensions' : ['jpg', 'png','gif'],
            'elErrorContainer': '#errorBlock'
        });
        /*
        $("#test-upload").on('fileloaded', function(event, file, previewId, index) {
            alert('i = ' + index + ', id = ' + previewId + ', file = ' + file.name);
        });
        */
    });
	</script>
  </body>
</html>
